FOR LINE = 1 TO 9 STEP 2
Here is the program, with the box replaced by the code it represents:
' Do the loop body ten times FOR LINE = 1 TO 10 LET NUM = LINE ' Print NUM stars in a row PRINT FOR STARS = 1 TO NUM PRINT "*"; NEXT STARS NEXT LINE ' END
This program can be simplified somewhat by noticing that
the variable NUM is not really needed,
since it always holds the same number as LINE
:
' Do the loop body ten times FOR LINE = 1 TO 10 ' Print LINE stars in a row PRINT FOR STARS = 1 TO ________ PRINT "*"; NEXT STARS NEXT LINE ' END
Fill in the blank so that LINE
number of stars are printed
each time the inner loop executes.